/**
 * Created by Yang on 2014/8/29.
 */

var menuJson =  {
    "button":[
        {
            "name":"新渭城介绍",
            "sub_button":[
                {
                    "type":"view",
                    "name":"关于立体城市·新渭城",
                    "url":"http://wx.tuuzii.com/wxView/show"
                },
                {
                    "type":"view",
                    "name":"楼盘介绍",
                    "url":"http://wx.tuuzii.com/wxView/user?showwxpaytitle=1"
                },
                {
                    "type":"view",
                    "name":"5%奖励活动",
                    "url":"http://wx.tuuzii.com/wxView/event2"
                }
            ]
        },
        {
            type:'view',
            name:'实名经纪人',
            url:"http://wx.tuuzii.com/wxView/agent?showwxpaytitle=1"
        },
        {
            "type":"click",
            "name":"市民中心",
            "key":"V1001_TODAY_SINGER"
        }
    ]
};

var wxToken = require('./tools/wxToken');
var wxMenu = require('./tools/wxMenu');
wxToken.init(function(accessToken){
   wxMenu.set(menuJson,function(){
       console.log('success');
   },function(err){
       console.log(err);
   })
});
